package com.yulebaby.callsenter.utils;

import com.yulebaby.callsenter.global.App;

import android.widget.Toast;


public class ToastUtil {

    private static Toast toast;

    public static void showToast(String text) {
        if (toast == null) {
            toast = Toast.makeText(App.mContext, text, Toast.LENGTH_SHORT);
        } else {
            toast.setText(text);
        }
        toast.show();
    }

    public static void showToastLong(String text) {
        if (toast == null) {
            toast = Toast.makeText(App.mContext, text, Toast.LENGTH_LONG);
        } else {
            toast.setText(text);
        }
        toast.show();
    }
}
